<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<title>修改用户</title>
		<%@ include file="../common/common1.jsp"%>
		
		<script type="text/javascript" src="js/jquery.min.js"></script>
		<link rel="stylesheet" href="css1/validation/validationEngine.jquery.css" type="text/css"/>
		<script src="js/validation/languages/jquery.validationEngine-zh_CN.js" ></script>
		<script src="js/validation/jquery.validationEngine.js" ></script>
		
		<script language="javascript" type="text/javascript">
		//修改用户
		function modUser() {
			var obj = document.getElementById('orgIdTemp');
			var orgIdS = "";
			if(obj != ""){
				var index=obj.selectedIndex; //序号，取当前选中选项的序号
				orgIdS = obj.options[index].value;
			}
			var userId = document.getElementById("userId").value;
			if (userId != "") {
				var form = document.getElementById('regform');
				form.action = "cms/manager/modUser.do?org.orgId="+orgIdS;
				form.submit();
			} else {
				window.alert("请选择用户！");
			}
		}
		//验证框架
			jQuery(document).ready(function(){
				// binds form submission and fields to the validation engine
				jQuery("#regform").validationEngine({
				promptPosition: "centerRight"});
	 		});
		</script>
	</head>
	 
		<div class="main-con">
			<!--//导航位置层-->
			<div class="main-bar">
				<span class="bar-position">当前位置：<a href="#">首页</a> 》 系统管理 》
					用户管理 》修改用户</span>
			</div>
			<div class="data-area">
				<s:form method="post"  action="cms/manager/modUser.do" id="regform" name="formMod">
					<table border="0" align="center" cellpadding="0" cellspacing="0"
						class="data-edite">
						<!--  
						<tr>
							<th colspan="2" class="waybill-title">
								<div align="center">
									<span>请填写修改用户的信息</span>
								</div>
							</th>
						</tr>
						-->
						<tr>
							<td>
								<input type="hidden" " name="user.userId" id="userId"
									readonly="readonly" class="data-searchtxt"
									value="<s:property value='user.userId'/>" />
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								用户名：
							</td>
							<td width="380">
								<input type="text" name="user.userName" id="userName"
									class="data-searchtxt"
									value="<s:property value='user.userName'/>" readonly="readonly" />
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								密码：
							</td>
							<td>
								<input type="text" name="user.userPwd" id="userPwd"
									class="data-searchtxt"
									value="<s:property value='user.userPwd'/>" readonly="readonly" />
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								邮箱：
							</td>
							<td>
								<input type="text" name="user.userEmail" id="userEmail"
									class="data-searchtxt validate[custom[email]]"
									value="<s:property value='user.userEmail'/>" />
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								性别：
							</td>
							<td>
								<select id="userMale" name="user.userMale"
									class="data-searchtxt" style="width: 45px">
									<s:if test="user.userMale == 0 ">
										<option id="userMaleT" value="0" selected="selected">
											男
										</option>
										<option id="userMaleT" value="1">
											女
										</option>
									</s:if>
									<s:else>
										<option id="userMaleT" value="1" selected="selected">
											女
										</option>
										<option id="userMaleT" value="0">
											男
										</option>
									</s:else>
								</select>
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								状态：
							</td>
							<td>
								<select id="userState" name="user.userState"
									class="data-searchtxt" style="width: 55px">
									<s:if test=" user.userState == 0 ">
										<option id="userStateT" value="0" selected="selected">
											启用
										</option>
										<option id="userStateT" value="1">
											停用
										</option>
										<option id="userStateT" value="2">
											删除
										</option>
									</s:if>
									<s:elseif test=" user.userState == 1 ">
										<option id="userStateT" value="0">
											启用
										</option>
										<option id="userStateT" value="1" selected="selected">
											停用
										</option>
										<option id="userStateT" value="2">
											删除
										</option>
									</s:elseif>
									<s:else>
										<option id="userStateT" value="0">
											启用
										</option>
										<option id="userStateT" value="1">
											停用
										</option>
										<option id="userStateT" value="2" selected="selected">
											删除
										</option>
									</s:else>
								</select>
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								开始时间：
							</td>
							<td>
								<input type="text" name="user.userStartDate" id="userStartDate"
									readonly="readonly" class="data-searchtxt"
									value="<s:property value='user.userStartDate'/>" />
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								结束时间：
							</td>
							<td>
								<input type="text" name="user.userEndDate" id="userEndDate"
									class="data-searchtxt Wdate required"
									onclick="WdatePicker({minDate:'#F{$dp.$D(\'userStartDate\');}'})"
									value="<s:property value='user.userEndDate'/>" />
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								电话：
							</td>
							<td>
								<input type="text" name="user.userMobile" id="userMobile"
									class="data-searchtxt 
											validate[optional,custom[phone],length[11,11]]"
									value="<s:property value='user.userMobile'/>" />
							</td>
						</tr>
						<tr>
							<td height="30" align="right">
								备注：
							</td>
							<td>
								<input type="text" name="user.userNote" id="userNote"
									class="data-searchtxt 
											validate[optional,length[5,100]]"
									value="<s:property value='user.userNote'/>" />
							</td>
						</tr>
						<tr>
							<td height="45" colspan="2" align="center">
								<input type="submit" name="button1" id="button1" class="btn-Yes"
									value="确 定"  />
								<input type="button" name="button2" id="button2" class="btn-No"
									value="返 回" onclick="history.go(-1);" />
							</td>
						</tr>
					</table>
				</s:form>
			</div>
		</div>
 
</html>
